<template>
    <div>
        <button @click="handleClick">click</button>
    </div>
</template>

<script>
export default {
    methods:{
        handleClick(){
            this.app.name += '1';
            console.log(this.a,this.app.name);
        }
    },
    // inject的使用也很简单，就和props差不多。不用我多说你也能看懂的吧
    inject: ["a","app"],
}
</script>